package platform.cmdexecutor;

import scripts.JarFileScriptRunner;

public class LinuxPlatformCommandExecutor extends PlatformCommandExecutor {

	private static LinuxPlatformCommandExecutor _instance;

	public static LinuxPlatformCommandExecutor getInstance() {
		if (_instance == null) {
			_instance = new LinuxPlatformCommandExecutor();
		}
		return _instance;
	}

	private LinuxPlatformCommandExecutor() {
	}

	@Override
	public void restartComputer() {
		JarFileScriptRunner scriptRunner = new JarFileScriptRunner("scripts/reboot_machine.sh");
		scriptRunner.executeScript();

	}

	@Override
	public void restartTeamViewer() {
		JarFileScriptRunner scriptRunner = new JarFileScriptRunner("scripts/restart_teamviewer_linux.sh");
		scriptRunner.executeScript();
	}
}
